<table class="tablesorter" cellspacing="0"> 
			<thead> 
				<tr> 
    				<th>Patient Name</th>
    				<th><center>Gender</center></th> 					    				    				
    				<th><center>Age</center></th>     				
    				<th><center>Primary Disease</center></th>
    				<th><center>Last Visit</center></th>
    				<th><center>Admitted</center></th>
    				<th><center>Readmission Risk</center></th>
				</tr> 
			</thead> 
			<tbody> 
<?php 

include 'db/db_Connect.php';                            
$username= $_SESSION['SESS_MEMBER_USERNAME'];

$result = mysql_query("SELECT * from patients WHERE discharged_on IS NULL and owned_by = '".$username."'");

while($row = mysql_fetch_array($result)){
	//Display the results in different cells
	echo 	"<tr><td>" 
		. $row['firstname']
		. " " . $row['lastname'] 		
		. "</td><td><center>" 
		. $row['gender']
		. "</center></td><td><center>" 
		. $row['age']
		. "</center></td><td><center>" 
		. $row['primary_disease']
				. "</center></td><td><center>" 
		. $row['']
		. "</center></center></td><td><center>" 
		. $row['admitted_on']
		. "</center></td><td><center>" 
		. $row['readmission_risk']	 	 	
		. "</center></td></tr>";
}
include 'db/db_Close.php';
?> 	
			</tbody> 
			</table>